﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="WebFormPub.aspx.cs" Inherits="Wsbs_WebFormPub" %>

<asp:Content  ContentPlaceHolderID="ContentPlaceHolderContent" Runat="Server" >
    <iframe marginheight="0" marginwidth="0" frameborder="0" scrolling="no" width="810" height=100% id="iframepage" name="iframepage" onLoad="iFrameHeight()"  style="text-align:center; margin:0 auto" >

    </iframe>
    <script type="text/javascript" language="javascript">
      
        function GetQueryString(name) {
            var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
            var r = window.location.search.substr(1).match(reg);
            if (r != null) return (r[2]); return null;
        }
        function iFrameHeight() {
            var ifm= document.getElementById("iframepage");
            var subWeb = document.frames ? document.frames["iframepage"].document :
    ifm.contentDocument;
            if(ifm != null && subWeb != null) {
                ifm.height = subWeb.body.scrollHeight;
            }
        }
      
        window.onload=function loadIframe() {
            var urlType = GetQueryString("type");
            var urlIid=GetQueryString("iid");
            var urlSj = GetQueryString("sj");
            var ifm = document.getElementById("iframepage");
            if (urlType == "0") {
                var url = '<%=System.Web.Configuration.WebConfigurationManager.AppSettings["sqrPingJiaUrl"]%>';
               
                ifm.src = url + '&readonly=false&UserId=-1&input_index=0&sj=' + urlSj + '&iid=' + urlIid + '';
               
            }
            else if (urlType == "1") {//投诉
                var url = '<%=System.Web.Configuration.WebConfigurationManager.AppSettings["sqrTouSuUrl"]%>';
                ifm.src = url+'&readonly=false&UserId=-1&input_index=0&iid=' + urlIid + '&type=1';
               
            }
        }
</script> 

</asp:Content>

